/**
 * OpportunityFollowUp实体类
 *
 * @author sxf
 * @email sxf02615@163.com
 * @date 2025/1/15
 */
package com.sxf.crm.entity;


import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.sxf.crm.enums.OpportunityFollowUpMethod;
import com.sxf.crm.enums.ReminderType;

import jakarta.persistence.*;
import lombok.Data;

/**
 * 跟进记录实体类
 * 
 * <p>用于记录商机和线索的跟进情况</p>
 * 
 * @author sxf
 * @email sxf02615@163.com
 * @date 2025/6/1
 */
@Data
@Entity
@Table(name = "opportunity_follow_ups")
@JsonIgnoreProperties({"hibernateLazyInitializer", "handler"})
public class OpportunityFollowUp {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private Long id;


    private Long opportunityId;
    
    @Enumerated(EnumType.STRING)
    @Column(name = "method")
    private OpportunityFollowUpMethod method; // 跟进方式（电话、邮件、面对面等）
    
    private String content; // 跟进内容
    private Long followUpTime; // 跟进时间
    private Long nextPlanTime; // 下次跟进计划时间
    private Boolean remind; // 是否提醒
    
    @Enumerated(EnumType.STRING)
    @Column(name = "remind_type")
    private ReminderType remindType; // 提醒类型（自动/手动）
    
    private Long remindTime; // 提醒时间
    private Long userId; // 跟进人ID
    private Long createAt;
    private Long createUserId;
    private Long updateAt;
    private Long updateUserId;
}